﻿using Top.Api;

namespace TaobaoAPIDAO
{
    public class BaseTopApiDao
    {
        //沙箱环境调用地址,
        //protected const string url = "http://gw.api.tbsandbox.com/router/rest";

        //正式环境需要设置为
        protected string url = "http://gw.api.taobao.com/router/rest";

        //实例化ITopClient类 
        protected ITopClient myclient ;

        //应用的Appkey
        protected string Appkey = Config.Appkey;

        //应用的密钥
        protected string Secret = Config.Secret;

        #region protected BaseTopApiDao() 构造函数。
        /// <summary>
        /// 构造函数。
        /// </summary>
        protected BaseTopApiDao()
        {
            myclient = new DefaultTopClient(url, Appkey, Secret);
        }
        #endregion

    }
}
